Finding the equation of a line